<template>
  <div>
    <header>
      <h1>大数据可视化-郑建洋-19819208372-前端工程师</h1>
      <!-- 大容器 -->
      <section class="container">
        <!-- 左容器 -->
        <section class="itemLeft">
          <ItemPage>
            <ItemOne></ItemOne>
          </ItemPage>
          <ItemPage>
            <ItemTwo></ItemTwo>
          </ItemPage>
        </section>
        <!-- 中容器 -->
        <section class="itemCenter">
          <!-- <h2>地图展示</h2> -->
          <MapPage />
        </section>
        <!-- 右容器 -->
        <section class="itemRight">
          <ItemPage>
            <ItemThree></ItemThree>
          </ItemPage>
          <ItemPage>
            <ItemFour></ItemFour>
          </ItemPage>
        </section>
      </section>
    </header>
  </div>
</template>

<script>
import ItemPage from "@/components/itemPage.vue";
import ItemOne from "@/components/itemOne.vue";
import ItemTwo from "@/components/itemTwo.vue";
import ItemThree from "@/components/itemThree.vue";
import ItemFour from "@/components/itemFour.vue";
import MapPage from "@/components/mapPage.vue";

import { inject } from "vue";

export default {
  setup() {
    let $echarts = inject("echarts");
    let $http = inject("axios");
    console.log($echarts);
    console.log($http);
  },
  components: {
    ItemPage,
    ItemOne,
    ItemTwo,
    ItemThree,
    ItemFour,
    MapPage,
  },
};
</script>

<style lang="less">
header {
  height: 1rem;
  width: 100%;
  background-color: rgba(0, 0, 255, 0.2);
  h1 {
    font-size: 0.375rem;
    color: #fff;
    text-align: center;
    line-height: 1rem;
  }
}
.container {
  // 最大最小宽度
  min-width: 1200px;
  max-width: 2048px;
  margin: 0 auto;
  border: 1px solid red;
  padding: 10px 10px 0;
  // height: 500px;
  // background-color: gray;
  display: flex;
  // 设置左右在页面的分数
  .itemLeft,
  .itemRight {
    flex: 3;
  }
  .itemCenter {
    flex: 5;
    // height: 10.5rpx; //840
    height: 10.5rpx; //840
    // height: 840px;
    border: 1px solid blue;
    padding: 10px;
    margin: 20px;
  }
}
</style>
